import Layout from '@/views/layout.vue'
import FindHouse from '@/views/secondes/FindHouse.vue'
import HomePage from '@/views/secondes/HomePage.vue'
import My from '@/views/secondes/My.vue'
import News from '@/views/secondes/news.vue'

import Fhdetail from '@/views/fhdetail.vue'
import Login from '@/views/login.vue'
import Register from '@/views/register.vue'
import HuntingMap from '@/views/HuntingMap.vue'
import Collect from '@/views/collect.vue'
import City from '@/views/city.vue'
import Release from '@/views/release.vue'
import Rent from '@/views/rent.vue'

const routes = [
  {
    path: '/',
    component: Layout,
    redirect: '/HomePage',

    children: [
      {
        name: 'HomePagele',
        path: 'HomePage',
        component: HomePage
      },
      {
        path: 'FindHouse',
        component: FindHouse
      },
      {
        path: 'news',
        component: News
      },
      {
        path: 'My',
        component: My
      }
    ]
  },
  {
    path: '/fhdetail/:id',
    component: Fhdetail,
    name: 'Fhdetail'
  },
  {
    path: 'HuntingMap',
    component: HuntingMap
  },
  { path: '/login', component: Login },
  { path: '/register', component: Register },
  { path: '/collect', component: Collect },
  { path: '/city', component: City },
  { path: '/release', component: Release },
  { path: '/rent', component: Rent }
]

export default routes
